package com.next

class TerritoryTeamImport
{
    Boolean notifyWhenStageChanges = false
    String notifyWhenStageChangesString

    Date startTime
    String startTimeString
    Date endTime
    String endTimeString
    //"YYYY-MM-DD"

    Territory territory
    String territoryExternalId
    User user
    String userExternalId

    String operation

    String status = 'Pendding'
    String description

    static mapping = {
        notifyWhenStageChangesString column: '`notify_when_change_string`'
    }

    static constraints = {
        //        teamRole nullable: true, blank: true
        notifyWhenStageChanges nullable: true, blank: true
        notifyWhenStageChangesString maxSize: 16
        startTime nullable: true, blank: true
        startTimeString maxSize: 10
        endTime nullable: true, blank: true
        endTimeString maxSize: 10
        territory nullable: true, blank: true
        territoryExternalId maxSize: 32
        user nullable: true, blank: true
        userExternalId maxSize: 32
        description nullable: true, blank: true, maxSize: 256

        status inList: ['Pending', 'Error', 'Successful'], maxSize: 10
        operation inList: ['Append', 'Delete'], maxSize: 6
    }
}
